Mega Code Archive

Categories
1) Android
2) ASP.Net
3) ASP.Net Tutorial
4) C
5) C Tutorial
6) C#
7) C# Book
8) C# by API
9) C# Tutorial
10) C++
11) C++ Tutorial
12) Delphi
13) Flash ActionScript
14) Flex
15) Java
16) Java Book
17) Java by API
18) Java Tutorial
19) JavaScript DHTML
20) JavaScript Reference
21) JavaScript Tutorial
22) MSOfficeExcel 2007 Tutorial
23) MSOfficePowerPoint 2007 Tutorial
24) MSOfficeWord 2007 Tutorial
25) MSSQL
26) MSSQL Tutorial
27) MySQL
28) MySQL Tutorial
29) Oracle PLSQL
30) Oracle PLSQL Tutorial
31) Perl
32) Php
33) PostgreSQL
34) Python
35) Python Tutorial
36) Ruby
37) Silverlight
38) VB.Net
39) VB.Net by API
40) VB.Net Tutorial
41) Visual C++ .NET
42) VisualBasic Script
43) XML
44) XML Tutorial
 
Php
1) Algorithms
2) Authentication
3) Calendar
4) Chart
5) Class
6) Code Snippets
7) Components
8) Content Management
9) Cookie Session
10) Data Type
11) Date Time
12) Design Patterns
13) Development
14) DNS
15) Email
16) File Directory
17) Form
18) Functions
19) Graphics
20) HTML
21) Language Basics
22) Login Authentication
23) Math
24) MySQL Database
25) Network
26) Operator
27) PDF
28) Reflection
29) Searching
30) Site Navigation
31) Statement
32) Statistics and Counters
33) Strings
34) User Management
35) Web Services SOAP WSDL
36) XML
Math
1) Abs( ) function returns the absolute value of the parameter
2) BCMath Functions
3) Both random generators provide functions to get the value of MAX_RAND
4) Calculate logarithms by dividing log() function with log(base)
5) Calculate logarithms with other base values by dividing the result of the log() function with log(base)
6) Calculation of e, the inverse nature of exp and log
7) Calling the Built-in abs() Function
8) Constants and switch statement
9) Constants, like the names of variables, are case-sensitivebut unlike variables
10) Convert integer values to other bases such as binary or base 32 and base 36
11) Create and use a simple static Math() class
12) Define a constant as an array or object
13) Dice Rolling Simulator
14) Difference between ceil and floor
15) Doing math with the bcmath extension
16) Doubles can be specified in scientific notation
17) Finding a random line of a file
18) Finding the Greatest and Least Values in a key-value pair
19) Finding the Greatest and Least Values in an Array
20) Float acos ( float num ) calculates the arc cosine value
21) Float asin ( float num ) calculates the arc sine value
22) Float atan ( float num ) calculates the arc tangent value
23) Float ceil ( float num ) rounds parameter to the nearest integer above its current value
24) Float cos ( float num ) calculates the cosine value of the number provided as its only parameter The parameter should be passed as ra
25) Float deg2rad ( float num ) converts degrees to radians
26) Float floor ( float num ) rounds it to the nearest integer below its current value
27) Float rad2deg ( float num ) converts radians to degrees
28) Float round ( float num [, int precision] ) rounds parameter to the nearest integer to its current value
29) Float sin ( float num ) calculates the sine value of the number provided as its only parameter
30) Float tan ( float num ) calculates the tangent value of the number
31) Floor in action
32) Function base_convert() converts any integer value from one base to another
33) Generate Password()
34) Generate random floating-point values from 0 to 10 with two decimals
35) Generate random numbers
36) Generate random numbers (integer values) between 0 and MAX_RAND by calling rand() or mt_rand() without any arguments
37) Get a random value from 5 to 25
38) Get random values from 10 to 10
39) Get the Power
40) Hyperbolic Functions
41) Int mt_rand ( [int min, int max] ) returns random numbers, similar to the rand( )
42) Int rand ( [int min, int max] ) returns random numbers
43) Math calculation
44) Math operations
45) Mathematical constants
46) Mt_rand with no arguments
47) Mt_rand with two arguments
48) Number decbin ( string binary_num ) converts a binary number into a decimal number
49) Number hexdec ( string hex_string ) converts a hexadecimal number into a decimal number
50) Number pow ( number base, number exponent), a base and a power to raise it by
51) Provide the number of decimal places to round to
52) Rand demo
53) Random floating-point values from 0 to 10 with two decimals
54) Random generators provide functions to get the value of MAX_RAND
55) Random Images
56) Random numbe with precision
57) Random Numbers
58) Random values are not restricted to positive integers The following example shows how to get random values from -10 to 10
59) Return the distance between two locations in either kilometers or miles
60) Round a double
61) Round in action
62) String base_convert ( string num, int from_base, int to_base ) convert every base to every other base
63) String decbin ( int num ) converts a decimal number into a binary number
64) String dechex ( int num ) converts a decimal number into a binary number
65) String decoct ( int num ) converts a decimal number into an octal number
66) Using the arbitrary-precision functions for exact integer arithmetic
67) Using the pow() function with integers, floats, and both negative and positive numbers
68) Using the trigonometric functions
69) You can either send a floating-point number or an integer to abs( )